/* 配置管理页面样式 */

:root {
    /* 使用与主页面一致的配色变量 */
    --primary-color: #f8f0e3;
    --secondary-color: #eadbc8;
    --accent-color: #e76f51;
    --accent-hover: #f4a261;
    --text-color: #433520;
    --bg-color: #faf6f0;
    --card-bg: #ffffff;
    --lighter-bg: #f5efe6;
    --border-color: #ddd0c0;
    --success-color: #6b9080;
    --warning-color: #e9c46a;
    --danger-color: #e63946;
    --code-bg: #f0e6d9;
    --shadow-color: rgba(67, 53, 32, 0.1);
    --primary-gradient: linear-gradient(135deg, #e76f51 0%, #f4a261 100%);
    --card-shadow: 0 4px 16px var(--shadow-color);
    --card-hover-shadow: 0 8px 24px var(--shadow-color);
    --border-radius: 12px;
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 24px;
    background-color: var(--bg-color);
    min-height: 100vh;
    color: var(--text-color);
}

.header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 32px;
    padding: 24px;
    background-color: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    box-shadow: var(--card-shadow);
}

.header h1 {
    margin: 0;
    color: var(--text-color);
    font-size: 2.5rem;
    font-weight: 700;
    letter-spacing: -0.02em;
    display: flex;
    align-items: center;
    gap: 12px;
}

.header h1::before {
    content: '⚙️';
    font-size: 2rem;
    filter: drop-shadow(2px 2px 4px rgba(0, 0, 0, 0.1));
}

.header-actions {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

.btn {
    padding: 12px 20px;
    border: none;
    border-radius: 10px;
    cursor: pointer;
    font-size: 13px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    transition: var(--transition);
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    position: relative;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
    transition: left 0.5s ease;
}

.btn:hover::before {
    left: 100%;
}

.btn:active {
    transform: translateY(1px);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

.btn-primary {
    background: var(--primary-gradient);
    color: white;
    border: 2px solid transparent;
}

.btn-primary::after {
    content: '✨';
    margin-left: 4px;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(231, 111, 81, 0.4);
}

.btn-secondary {
    background-color: var(--secondary-color);
    color: var(--text-color);
    border: 2px solid var(--border-color);
}

.btn-secondary::after {
    content: '↩️';
    margin-left: 4px;
}

.btn-secondary:hover {
    transform: translateY(-2px);
    background-color: var(--lighter-bg);
    box-shadow: var(--card-hover-shadow);
}

.btn-success {
    background-color: var(--success-color);
    color: white;
    border: 2px solid transparent;
}

.btn-success::after {
    content: '✓';
    margin-left: 4px;
}

.btn-success:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(107, 144, 128, 0.4);
}

.btn-danger {
    background-color: var(--danger-color);
    color: white;
    border: 2px solid transparent;
}

.btn-danger::after {
    content: '🗑️';
    margin-left: 4px;
}

.btn-danger:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(230, 57, 70, 0.4);
}

.btn-warning {
    background-color: var(--warning-color);
    color: var(--text-color);
    border: 2px solid transparent;
}

.btn-warning::after {
    content: '↻';
    margin-left: 4px;
}

.btn-warning:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(233, 196, 106, 0.4);
}

/* 搜索区域 */
.search-section {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 24px;
    padding: 20px;
    background-color: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    box-shadow: var(--card-shadow);
}

.search-box {
    position: relative;
    flex: 1;
    max-width: 400px;
}

.search-box input {
    width: 100%;
    padding: 14px 16px 14px 48px;
    border: 2px solid var(--border-color);
    border-radius: 12px;
    font-size: 14px;
    background-color: var(--lighter-bg);
    color: var(--text-color);
    transition: var(--transition);
    box-sizing: border-box;
}

.search-box input:focus {
    outline: none;
    border-color: var(--accent-color);
    background-color: var(--card-bg);
    box-shadow: 0 0 0 4px rgba(231, 111, 81, 0.1);
}

.search-box::before {
    content: '🔍';
    position: absolute;
    left: 16px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 16px;
    pointer-events: none;
    z-index: 1;
}

.config-stats {
    font-weight: 600;
    color: var(--accent-color);
    background-color: var(--lighter-bg);
    padding: 8px 16px;
    border-radius: 20px;
    font-size: 14px;
    white-space: nowrap;
    border: 1px solid var(--border-color);
}

/* 配置列表 */
.config-list {
    margin-bottom: 32px;
    display: grid;
    gap: 16px;
}

.config-item {
    display: grid;
    grid-template-columns: minmax(200px, 1fr) minmax(250px, 2fr) minmax(200px, 1.5fr) auto;
    gap: 24px;
    align-items: start;
    padding: 24px;
    background-color: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    box-shadow: var(--card-shadow);
    transition: var(--transition);
    position: relative;
    overflow: hidden;
}

.config-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 4px;
    height: 100%;
    background: var(--primary-gradient);
    opacity: 0;
    transition: var(--transition);
}

.config-item:hover {
    transform: translateY(-2px);
    box-shadow: var(--card-hover-shadow);
    border-color: var(--accent-color);
}

.config-item:hover::before {
    opacity: 1;
}

.config-key {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.config-key-label {
    font-weight: 600;
    color: var(--accent-color);
    font-size: 13px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 0;
    display: flex;
    align-items: center;
    gap: 6px;
}

.config-key-label::before {
    content: '🔑';
    font-size: 12px;
}

.config-key-input {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid var(--border-color);
    border-radius: 10px;
    font-family: 'JetBrains Mono', 'Courier New', monospace;
    font-size: 13px;
    font-weight: 500;
    background-color: var(--code-bg);
    color: var(--text-color);
    transition: var(--transition);
    box-sizing: border-box;
}

.config-key-input:focus {
    outline: none;
    border-color: var(--accent-color);
    background-color: var(--card-bg);
    box-shadow: 0 0 0 4px rgba(231, 111, 81, 0.1);
}

.config-value {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.config-value-label {
    font-weight: 600;
    color: var(--text-color, #333);
    font-size: 13px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 0;
    display: flex;
    align-items: center;
    gap: 6px;
}

.config-value-label::before {
    content: '📝';
    font-size: 12px;
}

.config-value-input {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid var(--border-color);
    border-radius: 10px;
    font-family: 'JetBrains Mono', 'Courier New', monospace;
    font-size: 13px;
    background-color: var(--lighter-bg);
    color: var(--text-color);
    transition: var(--transition);
    box-sizing: border-box;
}

.config-value-input:focus {
    outline: none;
    border-color: var(--success-color);
    background-color: var(--card-bg);
    box-shadow: 0 0 0 4px rgba(107, 144, 128, 0.1);
}

.config-comment {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.config-comment-label {
    font-weight: 600;
    color: var(--text-color, #333);
    font-size: 13px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 0;
    display: flex;
    align-items: center;
    gap: 6px;
}

.config-comment-label::before {
    content: '💬';
    font-size: 12px;
}

.config-comment-input {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid var(--border-color);
    border-radius: 10px;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    font-size: 13px;
    line-height: 1.5;
    min-height: 80px;
    resize: vertical;
    background-color: var(--lighter-bg);
    color: var(--text-color);
    transition: var(--transition);
    box-sizing: border-box;
}

.config-comment-input:focus {
    outline: none;
    border-color: var(--warning-color);
    background-color: var(--card-bg);
    box-shadow: 0 0 0 4px rgba(233, 196, 106, 0.2);
}

.config-actions {
    display: flex;
    flex-direction: column;
    gap: 12px;
    align-self: start;
    padding-top: 24px;
}

.config-actions .btn {
    padding: 10px 16px;
    font-size: 11px;
    min-width: 80px;
    text-align: center;
}

.config-actions .btn::after {
    margin-left: 2px;
}

/* 原始配置预览 */
.raw-config-section {
    margin-top: 32px;
    background-color: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    box-shadow: var(--card-shadow);
    padding: 24px;
    animation: fadeInUp 0.6s ease-out;
}

.raw-config-section h3 {
    margin-bottom: 16px;
    color: var(--accent-color);
    font-size: 1.5rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 8px;
}

.raw-config-section h3::before {
    content: '📄';
    font-size: 1.2rem;
}

#rawConfigPreview {
    width: 100%;
    height: 350px;
    padding: 20px;
    border: 2px solid var(--border-color);
    border-radius: 12px;
    font-family: 'JetBrains Mono', 'Courier New', monospace;
    font-size: 13px;
    line-height: 1.6;
    background-color: var(--code-bg);
    color: var(--text-color);
    resize: vertical;
    transition: var(--transition);
    box-sizing: border-box;
}

#rawConfigPreview:focus {
    outline: none;
    border-color: var(--accent-color);
    background-color: var(--card-bg);
    box-shadow: 0 0 0 4px rgba(231, 111, 81, 0.1);
}

/* 模态窗口 */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(8px);
    animation: modalFadeIn 0.3s ease-out;
}

@keyframes modalFadeIn {
    from {
        opacity: 0;
        backdrop-filter: blur(0px);
    }
    to {
        opacity: 1;
        backdrop-filter: blur(8px);
    }
}

.modal-content {
    background-color: var(--card-bg);
    margin: 5% auto;
    padding: 0;
    border-radius: var(--border-radius);
    width: 600px;
    max-width: 90%;
    box-shadow: 0 20px 60px var(--shadow-color);
    border: 1px solid var(--border-color);
    animation: modalSlideIn 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

@keyframes modalSlideIn {
    from {
        transform: translateY(-50px) scale(0.9);
        opacity: 0;
    }
    to {
        transform: translateY(0) scale(1);
        opacity: 1;
    }
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
    border-bottom: 1px solid var(--border-color, #e1e5e9);
}

.modal-header h3 {
    margin: 0;
    color: var(--accent-color);
}

.close {
    color: #aaa;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
}

.close:hover {
    color: #000;
}

.modal-body {
    padding: 20px;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: bold;
    color: var(--text-color);
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 10px;
    border: 2px solid var(--border-color);
    border-radius: 8px;
    font-size: 14px;
    background-color: var(--lighter-bg);
    color: var(--text-color);
    box-sizing: border-box;
    transition: var(--transition);
}

.form-group textarea {
    height: 80px;
    resize: vertical;
}

.modal-footer {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    padding: 20px;
    border-top: 1px solid var(--border-color);
    background-color: var(--lighter-bg);
}

/* Toast 提示 */
.toast {
    position: fixed;
    top: 24px;
    right: 24px;
    padding: 16px 24px;
    border-radius: 12px;
    color: white;
    font-weight: 600;
    font-size: 14px;
    z-index: 1100;
    opacity: 0;
    transform: translateX(100%) scale(0.9);
    transition: var(--transition);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.2);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    display: flex;
    align-items: center;
    gap: 8px;
    max-width: 400px;
}

.toast.show {
    opacity: 1;
    transform: translateX(0) scale(1);
}

.toast.success {
    background: linear-gradient(135deg, var(--success-color) 0%, #00b894 100%);
}

.toast.success::before {
    content: '✅';
}

.toast.error {
    background: linear-gradient(135deg, var(--danger-color) 0%, #e17055 100%);
}

.toast.error::before {
    content: '❌';
}

.toast.warning {
    background: linear-gradient(135deg, var(--warning-color) 0%, #f39c12 100%);
    color: #2d3436;
}

.toast.warning::before {
    content: '⚠️';
}

.toast.info {
    background: linear-gradient(135deg, var(--primary-color) 0%, #74b9ff 100%);
}

.toast.info::before {
    content: 'ℹ️';
}

/* 响应式设计 */

/* 大屏幕优化 */
@media (min-width: 1600px) {
    .container {
        max-width: 1600px;
        padding: 32px;
    }
    
    .config-item {
        grid-template-columns: minmax(250px, 1fr) minmax(300px, 2fr) minmax(250px, 1.5fr) auto;
        gap: 32px;
        padding: 32px;
    }
}

/* 中等屏幕适配 */
@media (max-width: 1200px) {
    .container {
        max-width: 100%;
        padding: 20px;
    }
    
    .config-item {
        grid-template-columns: minmax(180px, 1fr) minmax(220px, 2fr) minmax(180px, 1.5fr) auto;
        gap: 20px;
        padding: 20px;
    }
    
    .header h1 {
        font-size: 2.2rem;
    }
}

/* 平板端适配 */
@media (max-width: 992px) {
    .config-item {
        grid-template-columns: 1fr 1fr;
        grid-template-areas: 
            "key value"
            "comment actions";
        gap: 16px;
        padding: 20px;
    }
    
    .config-key {
        grid-area: key;
    }
    
    .config-value {
        grid-area: value;
    }
    
    .config-comment {
        grid-area: comment;
    }
    
    .config-actions {
        grid-area: actions;
        flex-direction: row;
        align-self: end;
        justify-content: flex-end;
        padding-top: 0;
    }
    
    .search-section {
        flex-direction: column;
        gap: 16px;
        text-align: center;
    }
    
    .search-box {
        max-width: 100%;
    }
}

/* 手机端适配 */
@media (max-width: 768px) {
    .container {
        padding: 16px;
        background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%);
    }
    
    .header {
        flex-direction: column;
        gap: 16px;
        padding: 20px;
        text-align: center;
    }
    
    .header h1 {
        font-size: 2rem;
    }
    
    .header-actions {
        justify-content: center;
        width: 100%;
    }
    
    .search-section {
        padding: 16px;
    }
    
    .config-item {
        grid-template-columns: 1fr;
        grid-template-areas: 
            "key"
            "value"
            "comment"
            "actions";
        gap: 16px;
        padding: 20px;
    }
    
    .config-actions {
        flex-direction: row;
        justify-content: center;
        gap: 8px;
        padding-top: 0;
    }
    
    .config-actions .btn {
        flex: 1;
        max-width: 120px;
    }
    
    .modal-content {
        width: 95%;
        margin: 5% auto;
        border-radius: 12px;
    }
    
    .btn {
        padding: 14px 20px;
        font-size: 12px;
    }
}

/* 小屏手机适配 */
@media (max-width: 480px) {
    .container {
        padding: 12px;
    }
    
    .header {
        padding: 16px;
    }
    
    .header h1 {
        font-size: 1.8rem;
    }
    
    .config-item {
        padding: 16px;
        gap: 12px;
    }
    
    .config-key-input,
    .config-value-input,
    .config-comment-input {
        padding: 10px 12px;
        font-size: 14px;
    }
    
    .config-actions {
        gap: 6px;
    }
    
    .config-actions .btn {
        padding: 12px 16px;
        font-size: 11px;
        min-width: 70px;
    }
    
    .search-section {
        padding: 12px;
    }
    
    .modal-content {
        width: 98%;
        margin: 2% auto;
    }
}

/* 深色主题支持 */
@media (prefers-color-scheme: dark) {
    :root {
        /* 深色主题下保持与主页面一致的配色 */
        --primary-color: #2d1b14;
        --secondary-color: #2d3748;
        --accent-color: #ff8a65;
        --accent-hover: #ff7043;
        --text-color: #e2e8f0;
        --bg-color: #1a202c;
        --card-bg: #2d3748;
        --lighter-bg: #4a5568;
        --border-color: #4a5568;
        --success-color: #68d391;
        --warning-color: #fbd38d;
        --danger-color: #fc8181;
        --code-bg: #2d3748;
        --shadow-color: rgba(0, 0, 0, 0.3);
        --primary-gradient: linear-gradient(135deg, #ff8a65 0%, #ff7043 100%);
        --card-shadow: 0 4px 16px var(--shadow-color);
        --card-hover-shadow: 0 8px 24px var(--shadow-color);
    }
    
    .container {
        background-color: var(--bg-color);
    }
    
    .header,
    .search-section,
    .config-item,
    .raw-config-section {
        background-color: var(--card-bg);
        border-color: var(--border-color);
    }
    
    .config-key-input,
    .config-value-input,
    .config-comment-input {
        background-color: var(--lighter-bg);
        color: var(--text-color);
        border-color: var(--border-color);
    }
    
    .config-key-input:focus,
    .config-value-input:focus,
    .config-comment-input:focus {
        background-color: var(--card-bg);
        border-color: var(--accent-color);
    }
    
    .search-box input,
    .form-group input,
    .form-group textarea,
    #rawConfigPreview {
        background-color: var(--lighter-bg);
        color: var(--text-color);
        border-color: var(--border-color);
    }
    
    .search-box input:focus,
    .form-group input:focus,
    .form-group textarea:focus,
    #rawConfigPreview:focus {
        background-color: var(--card-bg);
        border-color: var(--accent-color);
    }
    
    .modal-content {
        background-color: var(--card-bg);
        border-color: var(--border-color);
    }
    
    .modal-footer {
        background-color: var(--lighter-bg);
    }
}

/* 动画效果 */
.config-item {
    animation: fadeInUp 0.5s ease-out;
    animation-fill-mode: both;
}

.config-item:nth-child(1) { animation-delay: 0.1s; }
.config-item:nth-child(2) { animation-delay: 0.2s; }
.config-item:nth-child(3) { animation-delay: 0.3s; }
.config-item:nth-child(4) { animation-delay: 0.4s; }
.config-item:nth-child(5) { animation-delay: 0.5s; }
.config-item:nth-child(n+6) { animation-delay: 0.6s; }

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px) scale(0.95);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

/* 页面加载动画 */
.container {
    animation: containerFadeIn 0.8s ease-out;
}

@keyframes containerFadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* 按钮波纹效果 */
.btn {
    position: relative;
    overflow: hidden;
}

.btn::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.5);
    transform: translate(-50%, -50%);
    transition: width 0.6s, height 0.6s;
}

.btn:active::after {
    width: 300px;
    height: 300px;
}

/* 输入框聚焦动画 */
@keyframes inputFocus {
    0% {
        box-shadow: 0 0 0 0 rgba(102, 126, 234, 0.4);
    }
    70% {
        box-shadow: 0 0 0 10px rgba(102, 126, 234, 0);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(102, 126, 234, 0);
    }
}

.config-key-input:focus,
.config-value-input:focus,
.config-comment-input:focus,
.search-box input:focus {
    animation: inputFocus 0.6s ease-out;
}

/* 加载状态动画 */
.loading {
    position: relative;
    pointer-events: none;
}

.loading::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(90deg, transparent 0%, rgba(255, 255, 255, 0.4) 50%, transparent 100%);
    animation: loading 1.5s infinite;
    z-index: 1;
}

@keyframes loading {
    0% {
        transform: translateX(-100%);
    }
    100% {
        transform: translateX(100%);
    }
}

/* 悬浮动画 */
@keyframes float {
    0%, 100% {
        transform: translateY(0px);
    }
    50% {
        transform: translateY(-10px);
    }
}

.header h1::before {
    animation: float 3s ease-in-out infinite;
}

/* 成功动画 */
@keyframes successPulse {
    0% {
        box-shadow: 0 0 0 0 rgba(79, 172, 254, 0.7);
        transform: scale(1);
    }
    70% {
        box-shadow: 0 0 0 20px rgba(79, 172, 254, 0);
        transform: scale(1.05);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(79, 172, 254, 0);
        transform: scale(1);
    }
}

.config-item.success {
    animation: successPulse 0.6s ease-out;
}

/* 错误抖动动画 */
@keyframes shake {
    0%, 100% {
        transform: translateX(0);
    }
    10%, 30%, 50%, 70%, 90% {
        transform: translateX(-2px);
    }
    20%, 40%, 60%, 80% {
        transform: translateX(2px);
    }
}

.config-item.error {
    animation: shake 0.5s ease-out;
}

/* 滚动条美化 */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: rgba(0, 0, 0, 0.1);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb {
    background: var(--primary-gradient);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(135deg, #5a6acf 0%, #6a4c93 100%);
}

/* 配置项状态指示 */
.config-item.modified {
    border-left: 4px solid var(--warning-color);
    position: relative;
}

.config-item.modified::after {
    content: '✏️ 已修改';
    position: absolute;
    top: 12px;
    right: 12px;
    background: var(--warning-color);
    color: #2d3436;
    padding: 4px 8px;
    border-radius: 12px;
    font-size: 10px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    animation: pulse 2s infinite;
}

.config-item.new {
    border-left: 4px solid var(--success-color);
    position: relative;
}

.config-item.new::after {
    content: '✨ 新增';
    position: absolute;
    top: 12px;
    right: 12px;
    background: var(--success-color);
    color: white;
    padding: 4px 8px;
    border-radius: 12px;
    font-size: 10px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    animation: pulse 2s infinite;
}

.config-item.error {
    border-left: 4px solid var(--danger-color);
    position: relative;
}

.config-item.error::after {
    content: '⚠️ 错误';
    position: absolute;
    top: 12px;
    right: 12px;
    background: var(--danger-color);
    color: white;
    padding: 4px 8px;
    border-radius: 12px;
    font-size: 10px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% {
        opacity: 1;
        transform: scale(1);
    }
    50% {
        opacity: 0.7;
        transform: scale(1.05);
    }
}

/* 配置值类型提示 */
.config-type-hint {
    font-size: 11px;
    color: var(--text-color);
    opacity: 0.7;
    margin-top: 4px;
    font-style: italic;
    padding: 4px 8px;
    background-color: var(--lighter-bg);
    border: 1px solid var(--border-color);
    border-radius: 6px;
    display: inline-block;
    font-weight: 500;
} 
/* 智能助手悬浮按钮 */
.assistant-floating-btn {
    position: fixed;
    right: 30px;
    bottom: 140px;
    background: linear-gradient(45deg, #00d4aa, #a1c4fd);
    color: white;
    width: 55px;
    height: 55px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
    box-shadow: 0 4px 15px rgba(0, 212, 170, 0.3);
    transition: all 0.3s ease;
    text-decoration: none;
    z-index: 999;
}

.assistant-floating-btn:hover {
    transform: scale(1.15) translateY(-3px);
    box-shadow: 0 6px 20px rgba(0, 212, 170, 0.4);
    background: linear-gradient(45deg, #00e6c0, #b1d1ff);
    text-decoration: none;
    color: white;
}

.assistant-floating-btn i {
    animation: assistantPulse 2s infinite;
}

@keyframes assistantPulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.05); }
    100% { transform: scale(1); }
}

@media (max-width: 1024px) {
    .assistant-floating-btn {
        right: 20px;
        bottom: 140px;
        width: 50px;
        height: 50px;
        font-size: 20px;
    }
}

@media (max-width: 480px) {
    .assistant-floating-btn {
        right: 15px;
        bottom: 130px;
        width: 45px;
        height: 45px;
        font-size: 18px;
    }
}

@media (max-width: 360px) {
    .assistant-floating-btn {
        right: 15px;
        bottom: 120px;
        width: 40px;
        height: 40px;
        font-size: 16px;
    }
}
